﻿@model List<Menu>
@{
    Layout = null;
    var menus = Model;
}
<div class="indexbanner" style="overflow: hidden;">
    <a href="@Url.Action("Dashboard", "Index")" data-ajax-update="#Main" data-ajax-mode="replace" data-ajax-loading="#loading" data-ajax="true">
        <span style="float: left; width: 175px; height: 55px; cursor: pointer"></span>
    </a>
    <div style="min-width: 100px; color: White; float: right; padding-top: 5px; padding-left: 5px;
        padding-right: 5px">
        <table cellspacing="0" cellpadding="0" border="0" align="left">
            <tbody>
                <tr>
                    <td align="left">
                        <table>
                            <tbody>
                                <tr>
                                    <td>
                                        用户：
                                    </td>
                                    <td>
                                        admin <a href="javascript:void(0)" id="header_notice_num" class="notice_num" title="通知">
                                            0</a>
                                    </td>
                                </tr>
                                <tr>
                                    <td>
                                        科室：
                                    </td>
                                    <td>
                                        无
                                    </td>
                                </tr>
                            </tbody>
                        </table>
                    </td>
                </tr>
            </tbody>
        </table>
        <table cellspacing="0" cellpadding="0" border="0" align="right">
            <tbody>
                <tr>
                    <td height="10" colspan="10">
                    </td>
                </tr>
                <tr>
                    <td width="15">
                        <img width="25" height="26" alt="" src="/Content/images/navmenu_left.png">
                    </td>
                    <td class="navmenu_bg">
                        <img alt="" src="/Content/images/2_btn2.gif">
                    </td>
                    <td class="navmenu_bg">
                        @Ajax.ActionLink("首页", "Dashboard", "User", new { area = "admin" },new CustomAjaxOptions())
                    </td>
                    <td class="navmenu_bg">
                        <img alt="" src="/Content/images/2_btn3.gif">
                    </td>
                    <td class="navmenu_bg">
                        <a href="/Manager.aspx/Index/LeftMenu?menuID=1063701c-5682-4517-811b-c78650dc3daf"
                            data-ajax-update="#leftMenu" data-ajax-success="ajaxSuccess" data-ajax-mode="replace"
                            data-ajax-loading="#Loading" data-ajax-failure="ajaxError" data-ajax-complete="ajaxComplete"
                            data-ajax-begin="ajaxBegin" data-ajax="true">我的平台</a>
                    </td>
                    <td class="navmenu_bg">
                        <img width="16" onclick="showFeedbackDialog()" title="我要反馈" alt="反馈" style="cursor: pointer;"
                            src="/Content/images/2_btn1.gif" />
                    </td>
                    <td class="navmenu_bg">
                        <a onclick="showFeedbackDialog()" href="javascript:void(0)">反馈</a>
                    </td>
                    <td class="navmenu_bg">
                        <img alt="" src="/Content/images/2_btn4.gif">
                    </td>
                    <td class="navmenu_bg">
                        @Html.ActionLink("退出系统", "LogOff", "Account", new { area="admin" },null)
                    </td>
                    <td>
                        <img width="15" height="26" alt="" src="/Content/images/navmenu_right.png" />
                    </td>
                    <td>
                        &nbsp;
                    </td>
                </tr>
            </tbody>
        </table>
    </div>
</div>
<div style="overflow: hidden;" class="menu_bg">
    <table width="400" border="0" cellpadding="0" cellspacing="0">
        <tr>
            <td width="5" align="left">
                <img src="/Content/images/menu/menu_left.jpg" />
            </td>
            <td valign="middle" class="menu_center">
                <table width="100%" border="0" cellspacing="0" cellpadding="0">
                    <tr>
                        @foreach (var item in menus)
                        {
                            <td align="left" valign="middle" style="width: 120px;">
                                <table border="0" cellspacing="0" cellpadding="0" class="menu_pp">
                                    <tr>
                                        <td align="center" valign="middle">
                                            @if (item.SmallImageName == "" || item.SmallImageName == null)
                                            {
                                                <img src="/Content/images/menu/menu_Default.png" />
                                            }
                                            else
                                            {
                                                <img src="/Content/images/menu/@item.SmallImageName" />
                                            }
                                        </td>
                                        <td align="center" valign="middle">
                                            @{
                                            if (string.IsNullOrEmpty(item.Controller) || string.IsNullOrEmpty(item.Action))
                                            {
                                                @Ajax.ActionLink(item.MenuText, "leftMenu", "Menu", new { area = "admin", menuId = item.ID }, new CustomAjaxOptions() { UpdateTargetId = "leftMenu" });
                                            }
                                            else
                                            {
                                                @Ajax.ActionLink(item.MenuText, item.Action, item.Controller, new { area = item.Area, menuId = item.ID }, new CustomAjaxOptions() { UpdateTargetId = "main" });
                                            }
                                            }
                                        </td>
                                    </tr>
                                </table>
                            </td>
                        }
                    </tr>
                </table>
            </td>
            <td width="5" align="right">
                <img src="/Content/images/menu/menu_right.jpg" />
            </td>
        </tr>
    </table>
</div>
